Developer info
Here are some resources for developers. Twitch API Can be found here: https://github.com/justintv/twitch-api To get information about a channel, try: https://api.twitch.tv/kraken/channels/CHANNEL_NAME : There is more info here: http://api.justin.tv/api/stream/list.json?channel=CHANNEL_NAME : ...but the channel needs to be online. Twitch IRC Twitch has a IRC server you can connect to for chat. It is called TMI. It is really buggy. It will rendomly deop and op mods. You can recieve messages before a user joins a channel. If using PircBot, check onUserMode for mods and dont forget to check onUserList for people To connect to the server: server: irc.twitch.tv:6667 : find more servers at twitchstatus.com : I use 199.9.250.229:6667 and 199.9.250.229:6667 because they look more stable You cannot use SSL Nick is your twitch username Password is and oauth key (oauth:ds1fa2dsfa12d3sf1d2s3a1...) : get one at http://www.twitchapps.com/tmi All channels are #username in lowercase Usernames are all lowercase : If you want to find username casing, you have to lookup the user in Twitch API Users can send 20 messages in 30 seconds before getting global banned for 6 hours. Mods can send 100 messages in 30 seconds. (I think it is per channel?) You can only join 50 channels per second. Additional joins will fail. /join #username /part #username /userlist Joins and parts are batched together and sent every 5 seconds or so *it is possible to recieve a message before you recieve a join message from someone All "Twitch" commands are prefixed with a . .timeout (username) (secs) :: if no time specified, defaults to 600 secs .unban (username) :: --Also resets timeouts .ban (username) .subscribers .subscribersoff :: Even if you are not a partner you can use subscribers commands to restrict chat to only mods/owner TWITCHCLIENT JTVCLIENT is the same as TWITCHCLIENT, but use the twitch one. TWITCHCLIENT 1 is default. To change send /TWITCHCLIENT # TWITCHCLIENT by itself is the same as TWITCHCLIENT 1, and allows you to get userdata PMed to you by a user named "jtv." TWITCHCLIENT 2, however, is what the Twitch website uses nowadays. The big difference is that TWITCHCLIENT 2 prevents you from seeing channel joins and parts. TWITCHCLIENT 3 exists without documentation. from bwana: :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :SPECIALUSER george subscriber :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :USERCOLOR george #000000 :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :EMOTESET george 5,27 :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :CLEARCHAT kappa1 :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :You have banned kappa1 for 600 seconds. :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :This room is now in slow mode. You may send messages every 120 seconds :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :This room is no longer in slow mode. :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :This room is now in subscribers-only mode. :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :This room is no longer in subscribers-only mode. :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :The moderators of this room are: :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :This room is now in r9k mode. See http://bit.ly/bGtBDf :jtv!jtv@jtv.tmi.twitch.tv PRIVMSG #bwana :This room is no longer in r9k mode. : SPECIALUSER (admin/staff) are still private messages No JOIN/PART (same as TC 2) twitchnotify is now only sent to TC 3 users. (possibly a bug) USERCOLOR, SPECIALUSER (sub/turbo), EMOTESET, CLEARCHAT, and most/all command responses are sent from jtv as channel messages. Category:Developer